I've been stumped on an obscure problem while using XML-LibXML's XML::LibXML::Dtd. When trying to slurp the text of the DTD and call XML::LibXML::Dtd->parse_string as documented in the POD document, it still emitted an error. Now, I was including some DTD modules using the SYSTEM directive inside the DTD.
As it turns out I should have done this to start with:
my $dtd =
XML::LibXML::Dtd->new(
"Products Syndication Markup Language 0.1.1",
"products-syndication.dtd",
);
Call XML::LibXML::Dtd->new() with the docstring and the URL to the DTD. After I changed the code to using it everything worked fine. Problem is it is not documented anywhere in the POD. Guess I'll have to file a (yet another) XML::LibXML bug and attach a patch to the POD. <sigh /> - more work to do.
On a slightly differnet note if you want to learn XSLT, start at the W3Schools XSLT Tutorial (which is short and doesn't cover a lot of stuff, but still good) and proceed to the Zvon XSLT Tutorial (which covers almost everything, but requires some basic understanding.). Right now, I'd like to write an XSLT stylesheet (after I finish with the DTD), and these two tutorials finally caused the XSLT coin to fall.